-- GENERATED SPELL FOR [Dreghood Geomancer] --


function spell0_16937(pUnit, Event) --@Earth Shield,n/a--
pUnit:FullCastSpellOnTarget(32734,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16937', 523, 1)
end

function spell1_16937(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(34083,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_16937', 3000, 1)
end

function Sorts_16937(pUnit, Event)
local choix_sorts_16937 = math.random(0, 1)
if choix_sorts_16937 == 0 then
pUnit:RegisterEvent('spell0_16937', 1, 1)
end
if choix_sorts_16937 == 1 then
pUnit:RegisterEvent('spell1_16937', 1, 1)
end
end

function mob16937_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_16937', math.random(1500, 3000), 1)
end

function mob16937_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16937_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob16937_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(16937, 1, 'mob16937_Action')
RegisterUnitEvent(16937, 2, 'mob16937_Leave')
RegisterUnitEvent(16937, 3, 'mob16937_Kill')
RegisterUnitEvent(16937, 4, 'mob16937_Die')
